Optimal. Leaf size=281 \[ -\frac {2 (-1)^{2/3} a^{2/3} \tan ^{-1}\left (\frac {\sqrt [3]{-1} \sqrt [3]{b}-\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )}{\sqrt {a^{2/3}-(-1)^{2/3} b^{2/3}}}\right )}{3 \sqrt {a^{2/3}-(-1)^{2/3} b^{2/3}} b^{4/3} d}+\frac {2 a^{2/3} \tan ^{-1}\left (\frac {\sqrt [3]{b}+\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )}{\sqrt {a^{2/3}-b^{2/3}}}\right )}{3 \sqrt {a^{2/3}-b^{2/3}} b^{4/3} d}-\frac {2 \sqrt [3]{-1} a^{2/3} \tan ^{-1}\left (\frac {(-1)^{2/3} \sqrt [3]{b}+\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )}{\sqrt {a^{2/3}+\sqrt [3]{-1} b^{2/3}}}\right )}{3 \sqrt {a^{2/3}+\sqrt [3]{-1} b^{2/3}} b^{4/3} d}-\frac {\cos (c+d x)}{b d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.32, antiderivative size = 281, normalized size of antiderivative = 1.00, number of steps
used = 14, number of rules used = 5, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.217, Rules used = {3299, 2718,
2739, 632, 210} \begin {gather*} -\frac {2 (-1)^{2/3} a^{2/3} \text {ArcTan}\left (\frac {\sqrt [3]{-1} \sqrt [3]{b}-\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )}{\sqrt {a^{2/3}-(-1)^{2/3} b^{2/3}}}\right )}{3 b^{4/3} d \sqrt {a^{2/3}-(-1)^{2/3} b^{2/3}}}+\frac {2 a^{2/3} \text {ArcTan}\left (\frac {\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )+\sqrt [3]{b}}{\sqrt {a^{2/3}-b^{2/3}}}\right )}{3 b^{4/3} d \sqrt {a^{2/3}-b^{2/3}}}-\frac {2 \sqrt [3]{-1} a^{2/3} \text {ArcTan}\left (\frac {\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )+(-1)^{2/3} \sqrt [3]{b}}{\sqrt {a^{2/3}+\sqrt [3]{-1} b^{2/3}}}\right )}{3 b^{4/3} d \sqrt {a^{2/3}+\sqrt [3]{-1} b^{2/3}}}-\frac {\cos (c+d x)}{b d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 210
Rule 632
Rule 2718
Rule 2739
Rule 3299
Rubi steps
\begin {align*} \int \frac {\sin ^4(c+d x)}{a+b \sin ^3(c+d x)} \, dx &=\int \left (\frac {\sin (c+d x)}{b}-\frac {a \sin (c+d x)}{b \left (a+b \sin ^3(c+d x)\right )}\right ) \, dx\\ &=\frac {\int \sin (c+d x) \, dx}{b}-\frac {a \int \frac {\sin (c+d x)}{a+b \sin ^3(c+d x)} \, dx}{b}\\ &=-\frac {\cos (c+d x)}{b d}-\frac {a \int \left (-\frac {1}{3 \sqrt [3]{a} \sqrt [3]{b} \left (\sqrt [3]{a}+\sqrt [3]{b} \sin (c+d x)\right )}-\frac {(-1)^{2/3}}{3 \sqrt [3]{a} \sqrt [3]{b} \left (\sqrt [3]{a}-\sqrt [3]{-1} \sqrt [3]{b} \sin (c+d x)\right )}+\frac {\sqrt [3]{-1}}{3 \sqrt [3]{a} \sqrt [3]{b} \left (\sqrt [3]{a}+(-1)^{2/3} \sqrt [3]{b} \sin (c+d x)\right )}\right ) \, dx}{b}\\ &=-\frac {\cos (c+d x)}{b d}+\frac {a^{2/3} \int \frac {1}{\sqrt [3]{a}+\sqrt [3]{b} \sin (c+d x)} \, dx}{3 b^{4/3}}-\frac {\left (\sqrt [3]{-1} a^{2/3}\right ) \int \frac {1}{\sqrt [3]{a}+(-1)^{2/3} \sqrt [3]{b} \sin (c+d x)} \, dx}{3 b^{4/3}}+\frac {\left ((-1)^{2/3} a^{2/3}\right ) \int \frac {1}{\sqrt [3]{a}-\sqrt [3]{-1} \sqrt [3]{b} \sin (c+d x)} \, dx}{3 b^{4/3}}\\ &=-\frac {\cos (c+d x)}{b d}+\frac {\left (2 a^{2/3}\right ) \text {Subst}\left (\int \frac {1}{\sqrt [3]{a}+2 \sqrt [3]{b} x+\sqrt [3]{a} x^2} \, dx,x,\tan \left (\frac {1}{2} (c+d x)\right )\right )}{3 b^{4/3} d}-\frac {\left (2 \sqrt [3]{-1} a^{2/3}\right ) \text {Subst}\left (\int \frac {1}{\sqrt [3]{a}+2 (-1)^{2/3} \sqrt [3]{b} x+\sqrt [3]{a} x^2} \, dx,x,\tan \left (\frac {1}{2} (c+d x)\right )\right )}{3 b^{4/3} d}+\frac {\left (2 (-1)^{2/3} a^{2/3}\right ) \text {Subst}\left (\int \frac {1}{\sqrt [3]{a}-2 \sqrt [3]{-1} \sqrt [3]{b} x+\sqrt [3]{a} x^2} \, dx,x,\tan \left (\frac {1}{2} (c+d x)\right )\right )}{3 b^{4/3} d}\\ &=-\frac {\cos (c+d x)}{b d}-\frac {\left (4 a^{2/3}\right ) \text {Subst}\left (\int \frac {1}{-4 \left (a^{2/3}-b^{2/3}\right )-x^2} \, dx,x,2 \sqrt [3]{b}+2 \sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )\right )}{3 b^{4/3} d}+\frac {\left (4 \sqrt [3]{-1} a^{2/3}\right ) \text {Subst}\left (\int \frac {1}{-4 \left (a^{2/3}+\sqrt [3]{-1} b^{2/3}\right )-x^2} \, dx,x,2 (-1)^{2/3} \sqrt [3]{b}+2 \sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )\right )}{3 b^{4/3} d}-\frac {\left (4 (-1)^{2/3} a^{2/3}\right ) \text {Subst}\left (\int \frac {1}{-4 \left (a^{2/3}-(-1)^{2/3} b^{2/3}\right )-x^2} \, dx,x,-2 \sqrt [3]{-1} \sqrt [3]{b}+2 \sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )\right )}{3 b^{4/3} d}\\ &=-\frac {2 (-1)^{2/3} a^{2/3} \tan ^{-1}\left (\frac {\sqrt [3]{-1} \sqrt [3]{b}-\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )}{\sqrt {a^{2/3}-(-1)^{2/3} b^{2/3}}}\right )}{3 \sqrt {a^{2/3}-(-1)^{2/3} b^{2/3}} b^{4/3} d}+\frac {2 a^{2/3} \tan ^{-1}\left (\frac {\sqrt [3]{b}+\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )}{\sqrt {a^{2/3}-b^{2/3}}}\right )}{3 \sqrt {a^{2/3}-b^{2/3}} b^{4/3} d}-\frac {2 \sqrt [3]{-1} a^{2/3} \tan ^{-1}\left (\frac {(-1)^{2/3} \sqrt [3]{b}+\sqrt [3]{a} \tan \left (\frac {1}{2} (c+d x)\right )}{\sqrt {a^{2/3}+\sqrt [3]{-1} b^{2/3}}}\right )}{3 \sqrt {a^{2/3}+\sqrt [3]{-1} b^{2/3}} b^{4/3} d}-\frac {\cos (c+d x)}{b d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains higher order function than in optimal. Order 9 vs. order 3 in
optimal.
time = 0.18, size = 186, normalized size = 0.66 \begin {gather*} \frac {-3 \cos (c+d x)+a \text {RootSum}\left [-i b+3 i b \text {$\#$1}^2+8 a \text {$\#$1}^3-3 i b \text {$\#$1}^4+i b \text {$\#$1}^6\&,\frac {-2 \tan ^{-1}\left (\frac {\sin (c+d x)}{\cos (c+d x)-\text {$\#$1}}\right )+i \log \left (1-2 \cos (c+d x) \text {$\#$1}+\text {$\#$1}^2\right )+2 \tan ^{-1}\left (\frac {\sin (c+d x)}{\cos (c+d x)-\text {$\#$1}}\right ) \text {$\#$1}^2-i \log \left (1-2 \cos (c+d x) \text {$\#$1}+\text {$\#$1}^2\right ) \text {$\#$1}^2}{b-4 i a \text {$\#$1}-2 b \text {$\#$1}^2+b \text {$\#$1}^4}\&\right ]}{3 b d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
3.
time = 0.69, size = 104, normalized size = 0.37
method | result | size |
derivativedivides | \(\frac {-\frac {2}{b \left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}-\frac {2 a \left (\munderset {\textit {\_R} =\RootOf \left (a \,\textit {\_Z}^{6}+3 a \,\textit {\_Z}^{4}+8 b \,\textit {\_Z}^{3}+3 a \,\textit {\_Z}^{2}+a \right )}{\sum }\frac {\left (\textit {\_R}^{3}+\textit {\_R} \right ) \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-\textit {\_R} \right )}{\textit {\_R}^{5} a +2 \textit {\_R}^{3} a +4 \textit {\_R}^{2} b +\textit {\_R} a}\right )}{3 b}}{d}\) | \(104\) |
default | \(\frac {-\frac {2}{b \left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}-\frac {2 a \left (\munderset {\textit {\_R} =\RootOf \left (a \,\textit {\_Z}^{6}+3 a \,\textit {\_Z}^{4}+8 b \,\textit {\_Z}^{3}+3 a \,\textit {\_Z}^{2}+a \right )}{\sum }\frac {\left (\textit {\_R}^{3}+\textit {\_R} \right ) \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-\textit {\_R} \right )}{\textit {\_R}^{5} a +2 \textit {\_R}^{3} a +4 \textit {\_R}^{2} b +\textit {\_R} a}\right )}{3 b}}{d}\) | \(104\) |
risch | \(-\frac {{\mathrm e}^{i \left (d x +c \right )}}{2 b d}-\frac {{\mathrm e}^{-i \left (d x +c \right )}}{2 b d}+\frac {\left (\munderset {\textit {\_R} =\RootOf \left (\left (729 a^{2} b^{8} d^{6}-729 b^{10} d^{6}\right ) \textit {\_Z}^{6}+62208 a^{2} b^{6} d^{4} \textit {\_Z}^{4}+16777216 a^{4}\right )}{\sum }\textit {\_R} \ln \left ({\mathrm e}^{i \left (d x +c \right )}+\left (-\frac {243 a^{2} b^{7} d^{5}}{1048576 a^{4}+1048576 a^{2} b^{2}}+\frac {243 b^{9} d^{5}}{1048576 a^{4}+1048576 a^{2} b^{2}}\right ) \textit {\_R}^{5}+\left (\frac {1296 i d^{4} b^{5} a^{3}}{1048576 a^{4}+1048576 a^{2} b^{2}}-\frac {1296 i d^{4} b^{7} a}{1048576 a^{4}+1048576 a^{2} b^{2}}\right ) \textit {\_R}^{4}+\left (-\frac {13824 a^{2} b^{5} d^{3}}{1048576 a^{4}+1048576 a^{2} b^{2}}-\frac {6912 d^{3} b^{7}}{1048576 a^{4}+1048576 a^{2} b^{2}}\right ) \textit {\_R}^{3}+\left (\frac {73728 i d^{2} b^{3} a^{3}}{1048576 a^{4}+1048576 a^{2} b^{2}}+\frac {36864 i d^{2} b^{5} a}{1048576 a^{4}+1048576 a^{2} b^{2}}\right ) \textit {\_R}^{2}+\left (\frac {196608 d b \,a^{4}}{1048576 a^{4}+1048576 a^{2} b^{2}}+\frac {393216 d \,b^{3} a^{2}}{1048576 a^{4}+1048576 a^{2} b^{2}}\right ) \textit {\_R} -\frac {1048576 i a^{3} b}{1048576 a^{4}+1048576 a^{2} b^{2}}\right )\right )}{16}\) | \(403\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [C] Result contains complex when optimal does not.
time = 1.57, size = 21185, normalized size = 75.39 \begin {gather*} \text {too large to display} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\sin ^{4}{\left (c + d x \right )}}{a + b \sin ^{3}{\left (c + d x \right )}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 15.07, size = 665, normalized size = 2.37 \begin {gather*} \frac {\sum _{k=1}^6\ln \left (8192\,a^8\,b^5-{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^2\,a^6\,b^9\,294912+{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^3\,a^6\,b^{10}\,1548288-{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^4\,a^6\,b^{11}\,1990656-{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^5\,a^4\,b^{14}\,7962624+{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^5\,a^6\,b^{12}\,5971968-65536\,a^7\,b^6\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )\,a^7\,b^7\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,196608-{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^2\,a^7\,b^8\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,294912-{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^3\,a^5\,b^{11}\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,1769472+{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^3\,a^7\,b^9\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,221184-{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^4\,a^5\,b^{12}\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,2654208-{\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}^5\,a^5\,b^{13}\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,1990656\right )\,\mathrm {root}\left (729\,a^2\,b^8\,d^6-729\,b^{10}\,d^6+243\,a^2\,b^6\,d^4+a^4,d,k\right )}{d}-\frac {2}{b\,d\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+b\,d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________